package com.platform.service;

import com.platform.dao.ApiProdRelateShopMapper;
import com.platform.entity.ProductRelateShopDto;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;


@Service
public class ApiProdRelateShopService {
    @Autowired
    private ApiProdRelateShopMapper prodRelateShopDao;

    public void savaProdRelateShopDto(ProductRelateShopDto dto) {

        prodRelateShopDao.savaProdRelateShopDto(dto);
    }

    public void updateStockNum(ProductRelateShopDto dto) {

        prodRelateShopDao.updateStockNum(dto);
    }

    public void updateStockNumById(ProductRelateShopDto dto) {

        prodRelateShopDao.updateStockNumById(dto);
    }

    public ProductRelateShopDto queryByShopIdAndProdId(ProductRelateShopDto dto) {

        return prodRelateShopDao.queryByShopIdAndProdId(dto);
    }

    public ProductRelateShopDto queryByShopIdAndId(ProductRelateShopDto dto) {

        return prodRelateShopDao.queryByShopIdAndId(dto);
    }

}
